from django.urls import path
from .views import *
from rest_framework import routers

router = routers.DefaultRouter()
router.register(r'todo', TodoListViewSet, basename='todo')
router.register(r'user', UserViewSet, basename='users')

urlpatterns = [
    path('login', LoginView.as_view(), name='user_login'),
    path('logout', LogoutView.as_view(), name='user_logout'),
] + router.urls